package com.hshx.controller;

import com.hshx.client.SalaryClient;
import com.hshx.client.UsersClient;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.CrossOrigin;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.HashMap;

@CrossOrigin
@RequestMapping("/salaryService")
@RestController
public class WorkbenchController {
    @Autowired
    private UsersClient usersClient;
//    @Autowired
//    private SalaryClient salaryClient;
    /**
     *公司男女性别比例
     * @return
     */
    @RequestMapping("/genderRatio")
    public HashMap<String,Object> genderRatio(){
        HashMap<String,Object> hashMap = new HashMap<>();
        hashMap.put("male",usersClient.getManNumber());
        hashMap.put("female",usersClient.getWomanNumber());
        return hashMap;
    }

//    /**
//     * 薪酬标准分析
//     * @return
//     */
//    @RequestMapping("/standardAnalysis")
//    public HashMap<String,Object> standardAnalysis(){
//        return SalaryController.standardAnalyse1();
//    }

}
